-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Restructure create app to make it easier to upgrade deps #477
Conversation
`; | ||
}, | ||
}, | ||
}), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unified README's.
.vscode/settings.json
Outdated
@@ -5,7 +5,7 @@ | |||
"editor.defaultFormatter": "dprint.dprint" | |||
}, | |||
"[typescript]": { | |||
"editor.defaultFormatter": "vscode.typescript-language-features" | |||
"editor.defaultFormatter": "dprint.dprint" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure how this got changed but its doing the wrong formatting until now.
import * as fs from "node:fs/promises"; | ||
import * as path from "node:path"; | ||
import serialize from "serialize-javascript"; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code gen for each @osdk/create-app.template.*/src/generatedNoCheck/
@@ -79,16 +79,38 @@ export async function run( | |||
|
|||
consola.info(`Copying files into project directory`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Begin actual meat change for the template generation. Just writes from a map instead of cp from a directory.
@@ -141,12 +142,49 @@ async function checkExamples( | |||
`Found ${compareResult.differences} differences in ${exampleId} please generate examples again.`, | |||
); | |||
consola.error(compareResult.diffSet?.filter(d => d.state !== "equal")); | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Output proper diffs when things don't match
792f719
to
acff9d6
Compare
acff9d6
to
af052e0
Compare
af052e0
to
5b2ffc7
Compare
Changes:
Thankfully, the existence of the
examples
directory to validate the output of the generators means I was able to ensure this did not change the output!Note for reviewer:
@osdk/create-app.template.*
folders are just:packages/create-app/templates/X
->packages/create-app.template.X
(except X changed slightly).templates/package.json.hbs
file and put them inpackage.json
packages/create-app/src
and the new package that has the codegenpackages/create-app.template-packager
.